1. Technical Field
The present invention relates in general to a method and system for including file export information within a corresponding file system. Still more particularly, the present invention relates to a method and system for including export information in a file system extended attributes data area.
2. Description of the Related Art
The Network File System (NFS) is a distributed file system that allows users to access files and directories located on remote computers and treat those files and directories as if they were local. For example, users may use operating system commands to create, remove, read, write, and set file attributes for remote files and directories. NFS provides services through a client-server relationship. Computers that include file systems, or directories, or other resources available for remote access are called servers. Computers that use a server""s resources are considered clients.
The act of servers making file systems available for clients is called exporting. In traditional network file systems, a server has an export file that includes NFS information for file systems being accessed by the server. Upon boot-up, the server loads the export file into a kernel. The network file system kernel then performs a file system mounting process which makes the mounted file systems available for authorized clients.
If two servers access the same file systems on the same disk, each server has individual export files that are maintained by a system administrator. The export file includes information about the file system such as the location of file systems (pathname), who has access privileges, and if the file system is write protected. If a change in the export information is preferred, the system administrator modifies the export file on both servers. For example, if a new user is added to the access list for a file system, the system administrator adds the new user to the export file on both servers.
A challenge found in traditional systems is the ability to manage export information due the dynamics of a distributed network such as NFS. Tasks such as adding, deleting, relocating and changing file system export information often cause system administrators to update multiple export files. Each server has an export file that includes export information for file systems maintained by the server. If a file system""s export information changes, the system administrator makes changes to the export file for each server that supports the file system.
Another challenge found in traditional systems is during back-up and restore operations. When file systems are backed-up, the export information is not backed-up and linked to the corresponding file system. When the file system is restored, the export information needs to be added to the export file on the server. Adding the export information often includes the system administrator performing manual processes to add the appropriate export information.
What is needed, therefore, is a way to reduce file export information maintenance by including export information as part of the file system itself.
It has been discovered that by including NFS export information in a file system extended attributes data area, maintenance of the export information is reduced. The file system includes information about the files as well as an optional data area, called xe2x80x9cextended attributesxe2x80x9d for storing additional information about the file. In IBM""s AIX(trademark) operating system, the extended attribute data area is capable of storing thousands of additional bytes of information pertaining to data files. The export information is included in the file system itself and not in the export file on a server. When a new file system is created, the system administrator determines the file export information and provides it to the corresponding file system extended attributes. The system administrator determines export information that includes the location of the file system (pathname), who has access privileges, and if the file system is write protected. If the file system export information needs to be changed, the system administrator updates the export information in the file system extended attribute data area. For example, the system administrator updates the export information in the extended attribute data when a new user is allowed access to the file system. The system administrator can also select if he wants to have the NFS export information automatically provided to the kernel during a file mount. If the system administrator wants more control of what is exported, he may manually export the file.
Upon boot-up, the server issues mount commands to the file systems it wants to have access to. When the mount command is received, the file system provides export information included in the extended attributes to the kernel whereupon the kernel exports the file system. This makes the maintenance of the file exports automatic on file system mount and unmount. It also makes it easier to backup, replicate, and restore file systems. For example, when the system administrator backs up a file, the export information in the extended attributes is backed-up as well. When the file system is retrieved, the export information is also retrieved within the extended attributes.
The foregoing is a summary and thus contains, by necessity, simplifications, generalizations, and omissions of detail; consequently, those skilled in the art will appreciate that the summary is illustrative only and is not intended to be in any way limiting. Other aspects, inventive features, and advantages of the present invention, as defined solely by the claims, will become apparent in the non-limiting detailed description set forth below.